// window.AL_Framework_al_interface = {
//     showToast: function (e) {
//         var t = new cc.Node();
//         cc.director.getScene().addChild(t, 99999);
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         t.runAction(cc.sequence(cc.moveBy(0.7, 0, 200).easing(cc.easeBackOut(2)), cc.fadeOut(0.7), cc.removeSelf()));
//         var o = new cc.Node();
//         t.addChild(o);
//         o.addComponent(cc.Sprite);
//         ailin_load("common/toastBg", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             o.getComponent(cc.Sprite).spriteFrame.insetTop = 13;
//             o.getComponent(cc.Sprite).spriteFrame.insetBottom = 13;
//             o.getComponent(cc.Sprite).spriteFrame.insetLeft = 13;
//             o.getComponent(cc.Sprite).spriteFrame.insetRight = 13;
//             o.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//             o.getComponent(cc.Sprite).type = cc.Sprite.Type.SLICED;
//             o.width = 40;
//             o.height = 93;
//         });
//         var i = o.addComponent(cc.Layout);
//         i.resizeMode = cc.Layout.ResizeMode.CONTAINER;
//         i.paddingLeft = 20;
//         i.paddingRight = 20;
//         i.paddingTop = 15;
//         i.paddingBottom = 15;
//         var n = new cc.Node();
//         o.addChild(n);
//         var a = n.addComponent(cc.Label);
//         a.fontSize = 35;
//         a.string = e;
//     },
//     showModal: function (e) {
//         cc.loader.loadRes("Flower/module/modal/modalNode", function (t, o) {
//             try {
//                 var i = cc.instantiate(o);
//                 i.x = cc.winSize.width / 2;
//                 i.y = cc.winSize.height / 2;
//                 i.getComponent("AL_Framework_al_modal").shezhi_shuju_duixiang(e);
//                 cc.director.getScene().addChild(i);
//             } catch (e) {}
//         });
//     },
//     xianshi_layer_ceng: function (e) {
//         var t = new cc.Node();
//         cc.director.getScene().addChild(t);
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         var o = new cc.Node();
//         t.addChild(o);
//         o.addComponent(cc.Sprite);
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             o.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//             o.width = cc.winSize.width;
//             o.height = cc.winSize.height;
//         });
//         o.width = cc.winSize.width;
//         o.height = cc.winSize.height;
//         o.opacity = 200;
//         var i = new cc.Node();
//         t.addChild(i);
//         var n = i.addComponent(cc.Label);
//         n.overflow = cc.Label.Overflow.RESIZE_HEIGHT;
//         n.horizontalAlign = cc.Label.HorizontalAlign.CENTER;
//         n.verticalAlign = cc.Label.VerticalAlign.CENTER;
//         i.width = cc.winSize.width;
//         n.fontSize = 35;
//         n.string = e;
//         o.addComponent(cc.Button);
//         o.on("click", function () {
//             t.destroy();
//         });
//     },
//     showLoading: function (t) {
//         var o = new cc.Node();
//         cc.director.getScene().addChild(o);
//         o.x = cc.winSize.width / 2;
//         o.y = cc.winSize.height / 2;
//         var i = new cc.Node();
//         o.addChild(i);
//         i.addComponent(cc.Sprite);
//         i.addComponent(cc.BlockInputEvents);
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, t) {
//             i.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             i.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//             i.width = cc.winSize.width;
//             i.height = cc.winSize.height;
//         });
//         i.width = cc.winSize.width;
//         i.height = cc.winSize.height;
//         i.opacity = 200;
//         i.addComponent(require("./AL_Framework_al_loading")).chushihua_view(t);
//         return o;
//     },
//     xianshi_weixin_erweima: function () {
//         var e = new cc.Node();
//         e.width = cc.winSize.width;
//         e.height = cc.winSize.height;
//         e.x = cc.winSize.width / 2;
//         e.y = cc.winSize.height / 2;
//         e.addComponent(cc.BlockInputEvents);
//         e.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg.png", function (t, o) {
//             e.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(o);
//             e.width = cc.winSize.width;
//             e.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         cc.director.getScene().addChild(e);
//         cc.game.addPersistRootNode(e);
//         var t = new cc.Node();
//         e.addChild(t);
//         t.addComponent(cc.Sprite);
//         cc.loader.load("http://idata.flowerme.com/h5/commonResource/wechatCode.png", function (e, o) {
//             var i = new cc.SpriteFrame();
//             i.setTexture(o);
//             t.addComponent(cc.Sprite).spriteFrame = i;
//         });
//         var o = new cc.Node();
//         t.addChild(o, 999);
//         o.y = -225;
//         o.addComponent(cc.Sprite);
//         cc.loader.load("http://idata.flowerme.com/h5/commonResource/btnCopy.png", function (e, t) {
//             var i = new cc.SpriteFrame();
//             i.setTexture(t);
//             o.addComponent(cc.Sprite).spriteFrame = i;
//         });
//         o.on(
//             cc.Node.EventType.TOUCH_END,
//             function () {
//                 cc.loader.load("http://idata.flowerme.com/h5/commonResource/wxCopy.txt", function (e, t) {
//                     webCopyString(t);
//                 });
//             },
//             o
//         );
//         var i = new cc.Node();
//         t.addChild(i);
//         i.y = 274;
//         i.x = 207;
//         i.addComponent(cc.Sprite);
//         cc.loader.load("http://idata.flowerme.com/h5/commonResource/x.png", function (t, o) {
//             var n = new cc.SpriteFrame();
//             n.setTexture(o);
//             i.addComponent(cc.Sprite).spriteFrame = n;
//             i.on(
//                 cc.Node.EventType.TOUCH_END,
//                 function () {
//                     e.destroy();
//                 },
//                 i
//             );
//         });
//     },
//     xianshi_weixin_juzhen: function (e, t) {
//         if (void 0 === e) {
//             e = null;
//         }
//         if (void 0 === t) {
//             t = !0;
//         }
//         var o = new cc.Node();
//         o.width = cc.winSize.width;
//         o.height = cc.winSize.height;
//         o.x = cc.winSize.width / 2;
//         o.y = cc.winSize.height / 2;
//         o.addComponent(cc.BlockInputEvents);
//         o.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("common/bg2", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             o.width = cc.winSize.width;
//             o.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         cc.director.getScene().addChild(o);
//         var i = new cc.Node();
//         o.addChild(i, 2);
//         i.addComponent(cc.Sprite);
//         i.x = 0;
//         i.y = cc.winSize.height / 2 - 100;
//         ailin_load("common/sl", function (e, t) {
//             i.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             console.log("btn===========titleNode ", i);
//         });
//         var n = new cc.Node();
//         o.addChild(n, 2);
//         n.y = -cc.winSize.height / 2 + 150;
//         n.addComponent(cc.Sprite);
//         ailin_load("common/jx", function (e, t) {
//             n.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             console.log("btn===========btnContinue ", n);
//         });
//         n.on(
//             cc.Node.EventType.TOUCH_END,
//             function () {
//                 if (e) {
//                     e();
//                 }
//                 o.destroy();
//             },
//             n
//         );
//         ailin_sdk_manager.instance.show_Custom_Ad({
//             node: o
//         });
//         ailin_sdk_manager.yincangBannerGuanggao();
//         ailin_sdk_manager.guanbiHeziBannerGuanggao();
//     },
//     xianshiYinsixieyi: function (e) {
//         if (void 0 === e) {
//             e = null;
//         }
//         var t = new cc.Node();
//         t.width = cc.winSize.width;
//         t.height = cc.winSize.height;
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         t.addComponent(cc.BlockInputEvents);
//         t.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, o) {
//             t.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(o);
//             t.width = cc.winSize.width;
//             t.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         cc.director.getScene().addChild(t);
//         cc.game.addPersistRootNode(t);
//         var o = new cc.Node();
//         o.width = 624;
//         o.height = 710;
//         cc.winSize.width < cc.winSize.height ? (o.scale = cc.winSize.width / 720) : (o.scale = cc.winSize.height / 720);
//         t.addChild(o);
//         o.addComponent(cc.Sprite).type = cc.Sprite.Type.SIMPLE;
//         o.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         var i = cc.winSize.width > cc.winSize.height;
//         ailin_load(i ? "yinsixieyi/hb/ys_bg" : "yinsixieyi/ys_bg", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             i ? ((o.width = 840), (o.height = 580)) : ((o.width = 500), (o.height = 710));
//         });
//         var n = new cc.Node();
//         n.addComponent(cc.Sprite);
//         n.addComponent(cc.Button);
//         n.on("click", function () {
//             console.log("ailin ----------------- btnYsxy");
//             14 == ailin_sdk_manager.huoqu_xitong_pingtai()
//                 ? jsb.reflection.callStaticMethod(
//                       "MyManager",
//                       "OpenYinsiOrUser:type:",
//                       "huaxun" == window.ailin_huawei_team ? 1 : 0,
//                       0
//                   )
//                 : AL_Framework_al_interface.showBodyYS();
//         });
//         var a = new cc.Node();
//         a.addComponent(cc.Sprite);
//         a.addComponent(cc.Button);
//         a.on("click", function () {
//             console.log("ailin ----------------- yhxy");
//             14 == ailin_sdk_manager.huoqu_xitong_pingtai()
//                 ? jsb.reflection.callStaticMethod(
//                       "MyManager",
//                       "OpenYinsiOrUser:type:",
//                       "huaxun" == window.ailin_huawei_team ? 1 : 0,
//                       1
//                   )
//                 : AL_Framework_al_interface.showBodyYS("1");
//         });
//         var s = new cc.Node();
//         s.addComponent(cc.Sprite);
//         ailin_load("yinsixieyi/btnJJ", function (e, t) {
//             s.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         s.addComponent(cc.Button);
//         s.on("click", function () {
//             0 == ailin_sdk_manager.instance.xieyi_shezhi
//                 ? AL_Framework_al_interface.xianshiYinsixieyiTishi(function () {
//                       t.destroy();
//                   })
//                 : (t.destroy(), e && e());
//         });
//         var r = new cc.Node();
//         r.addComponent(cc.Button);
//         r.addComponent(cc.Sprite);
//         ailin_load("yinsixieyi/btnTY", function (e, t) {
//             r.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         r.on("click", function () {
//             ailin_sdk_manager.youxiTongyongShijianChuli("30001");
//             ailin_user_default.set_bool_for_key("lieyou_huawei_needShowOk", !1);
//             cc.director.resume();
//             if (e) {
//                 e();
//             }
//             t.destroy();
//         });
//         i
//             ? ((n.position = cc.v2(31, -32)),
//               (n.width = 99),
//               (n.height = 19),
//               (a.position = cc.v2(-161, -32)),
//               (a.width = 99),
//               (a.height = 19),
//               (s.position = cc.v2(-150, -210)),
//               (r.x = 150),
//               (r.y = -210))
//             : ((n.position = cc.v2(165, -18)),
//               (n.width = 99),
//               (n.height = 19),
//               (a.position = cc.v2(-150, -49)),
//               (a.width = 99),
//               (a.height = 19),
//               (r.position = cc.v2(120, -240)),
//               (s.position = cc.v2(-120, -240)));
//         o.addChild(n);
//         o.addChild(a);
//         o.addChild(r);
//         o.addChild(s);
//     },
//     xianshiYinsixieyiTishi: function (e) {
//         if (void 0 === e) {
//             e = null;
//         }
//         var t = new cc.Node();
//         t.width = cc.winSize.width;
//         t.height = cc.winSize.height;
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         t.addComponent(cc.BlockInputEvents);
//         t.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, o) {
//             t.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(o);
//             t.width = cc.winSize.width;
//             t.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         cc.director.getScene().addChild(t);
//         cc.game.addPersistRootNode(t);
//         var o = new cc.Node();
//         o.width = 624;
//         o.height = 710;
//         cc.winSize.width < cc.winSize.height ? (o.scale = cc.winSize.width / 720) : (o.scale = cc.winSize.height / 720);
//         t.addChild(o);
//         o.addComponent(cc.Sprite).type = cc.Sprite.Type.SIMPLE;
//         o.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("tt/share_bg", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             o.width = 510;
//             o.height = 310;
//         });
//         var i = new cc.Node();
//         i.addComponent(cc.Sprite);
//         i.position = cc.v2(0, 52);
//         ailin_load("yinsixieyi/tips", function (e, t) {
//             i.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         var n = new cc.Node();
//         n.addComponent(cc.Sprite);
//         n.position = cc.v2(-110, -95);
//         ailin_load("yinsixieyi/btnJJ", function (e, t) {
//             n.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         n.addComponent(cc.Button);
//         n.on("click", function () {
//             if (0 == ailin_sdk_manager.instance.xieyi_shezhi) {
//                 var o = ailin_sdk_manager.huoqu_xitong_pingtai();
//                 3 == o || 4 == o
//                     ? qg.exitApplication({})
//                     : 1 == o
//                     ? wx.exitMiniProgram({})
//                     : 11 == o
//                     ? qq.exitMiniProgram({})
//                     : 8 == o
//                     ? tt.exitMiniProgram({})
//                     : cc.game.end();
//             } else {
//                 t.destroy();
//                 e && e();
//             }
//         });
//         var a = new cc.Node();
//         a.x = 110;
//         a.y = -95;
//         a.addComponent(cc.Button);
//         a.addComponent(cc.Sprite);
//         ailin_load("yinsixieyi/btnTY", function (e, t) {
//             a.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         a.on("click", function () {
//             ailin_sdk_manager.youxiTongyongShijianChuli("30001");
//             ailin_user_default.set_bool_for_key("lieyou_huawei_needShowOk", !1);
//             cc.director.resume();
//             if (e) {
//                 e();
//             }
//             t.destroy();
//         });
//         o.addChild(i);
//         o.addChild(a);
//         o.addChild(n);
//     },
//     xianshiDingdanTishi: function (e, t) {
//         if (void 0 === e) {
//             e = "";
//         }
//         if (void 0 === t) {
//             t = null;
//         }
//         var o = new cc.Node();
//         o.width = cc.winSize.width;
//         o.height = cc.winSize.height;
//         o.x = cc.winSize.width / 2;
//         o.y = cc.winSize.height / 2;
//         var i = new cc.Node();
//         i.width = cc.winSize.width;
//         i.height = cc.winSize.height;
//         i.opacity = 150;
//         i.addComponent(cc.BlockInputEvents);
//         i.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, t) {
//             i.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             i.width = cc.winSize.width;
//             i.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         o.addChild(i);
//         cc.director.getScene().addChild(o);
//         cc.game.addPersistRootNode(o);
//         var n = new cc.Node();
//         n.width = 624;
//         n.height = 710;
//         cc.winSize.width < cc.winSize.height ? (n.scale = cc.winSize.width / 720) : (n.scale = cc.winSize.height / 720);
//         o.addChild(n);
//         n.addComponent(cc.Sprite).type = cc.Sprite.Type.SIMPLE;
//         n.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("q_ad/nativeEmbedBg", function (e, t) {
//             n.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             n.width = 510;
//             n.height = 310;
//         });
//         var a = new cc.Node();
//         a.addComponent(cc.Sprite);
//         a.position = cc.v2(0, 105);
//         ailin_load("yinsixieyi/wxtips", function (e, t) {
//             a.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         var s = new cc.Node();
//         s.color = cc.color(0, 0, 0);
//         var r = s.addComponent(cc.Label);
//         r.string = e;
//         r.fontSize = 24;
//         r.lineHeight = 25;
//         var c = new cc.Node();
//         c.x = 0;
//         c.y = -95;
//         c.addComponent(cc.Button);
//         c.addComponent(cc.Sprite);
//         ailin_load("yinsixieyi/btnOK", function (e, t) {
//             c.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         c.on("click", function () {
//             ailin_user_default.set_bool_for_key("lieyou_huawei_needShowOk", !1);
//             cc.director.resume();
//             if (t) {
//                 t();
//             }
//             o.destroy();
//         });
//         n.addChild(a);
//         n.addChild(s);
//         n.addChild(c);
//     },
//     showBodyYS: function (e) {
//         if (void 0 === e) {
//             e = "2";
//         }
//         "1" == e || (cc.sys.isNative && (cc.sys.os == cc.sys.OS_IOS || cc.sys.os == cc.sys.ANDROID))
//             ? AL_Framework_al_interface.showBodyYS1(e)
//             : AL_Framework_al_interface.showBodyYS2(e);
//     },
//     showBodyYS1: function (e) {
//         if (void 0 === e) {
//             e = "2";
//         }
//         var t = new cc.Node();
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         t.width = cc.winSize.width;
//         t.height = cc.winSize.height;
//         t.addComponent(cc.BlockInputEvents);
//         t.addComponent(cc.Sprite);
//         t.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("common/whiteBg.png", function (e, o) {
//             t.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(o);
//             t.width = cc.winSize.width;
//             t.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         var o = new cc.Node();
//         var i = o.addComponent(cc.ScrollView);
//         i.horizontal = !1;
//         var n = new cc.Node();
//         n.addComponent(cc.Mask);
//         var a = new cc.Node();
//         var s = a.addComponent(cc.Layout);
//         s.paddingTop = 0;
//         s.paddingBottom = 110;
//         s.type = cc.Layout.Type.VERTICAL;
//         s.verticalDirection = cc.Layout.VerticalDirection.TOP_TO_BOTTOM;
//         s.resizeMode = cc.Layout.ResizeMode.CONTAINER;
//         o.width = cc.winSize.width;
//         o.height = cc.winSize.height;
//         a.width = cc.winSize.width;
//         n.height = cc.winSize.height;
//         n.width = cc.winSize.width;
//         o.y = cc.winSize.height / 2;
//         o.anchorY = 1;
//         n.anchorY = 1;
//         a.anchorY = 1;
//         var r = new cc.Node();
//         r.addComponent(cc.Button);
//         r.addComponent(cc.Sprite);
//         r.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         var c = new cc.Node();
//         var l = c.addComponent(cc.Label);
//         c.color = cc.Color.BLACK;
//         l.string = "X";
//         l.fontSize = 50;
//         l.lineHeight = 60;
//         r.width = cc.winSize.width;
//         r.height = 100;
//         r.y = -cc.winSize.height / 2 + 30;
//         r.color = cc.Color(211, 211, 211);
//         ailin_load("common/whiteBg.png", function (e, t) {
//             r.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             r.width = cc.winSize.width;
//             r.height = 100;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         o.addChild(n);
//         n.addChild(a);
//         i.content = a;
//         t.addChild(o);
//         r.addChild(c);
//         t.addChild(r, 101);
//         cc.director.getScene().addChild(t, 9999);
//         r.on("click", function () {
//             t.destroy();
//         });
//         var d = "";
//         if (cc.winSize.width > cc.winSize.height) {
//             d = "_lan";
//         }
//         var u = "ailin";
//         "leYou" == window.ailin_huawei_team
//             ? (u = "leyouxi")
//             : "lieYou" == window.ailin_huawei_team
//             ? (u = "ailin")
//             : "dazheng" == window.ailin_huawei_team
//             ? (u = "dazheng")
//             : "jianyou" == window.ailin_huawei_team
//             ? (u = "jianyou")
//             : "zhangShangLeYuan" == window.ailin_huawei_team && (u = "zsleyuan");
//         var h = "privacypolicy_";
//         if ("1" == e) {
//             h = "agreement_";
//         }
//         var p = "https://idata.flowerme.com/comm/company/" + u + d + "/app/src/main/assets/";
//         14 != ailin_sdk_manager.huoqu_xitong_pingtai()
//             ? AL_Framework_al_interface.addImage(p + h, 1, a)
//             : jsb.reflection.callStaticMethod(
//                   "MyManager",
//                   "OpenYinsiOrUser:type:",
//                   "huaxun" == u ? 1 : 0,
//                   "1" == e ? 1 : 0
//               );
//     },
//     showBodyYS2: function (e) {
//         if (void 0 === e) {
//             e = "2";
//         }
//         var t = new cc.Node();
//         t.name = "22222";
//         t.width = cc.winSize.width;
//         t.height = cc.winSize.height;
//         t.x = cc.winSize.width / 2;
//         t.y = cc.winSize.height / 2;
//         t.addComponent(cc.BlockInputEvents);
//         t.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("qgameMoreGame/oppo_native_insters_layerBg", function (e, o) {
//             t.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(o);
//             t.width = cc.winSize.width;
//             t.height = cc.winSize.height;
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         cc.director.getScene().addChild(t, 9999);
//         var o = new cc.Node();
//         t.addChild(o);
//         o.addComponent(cc.Sprite);
//         o.getComponent(cc.Sprite).type = cc.Sprite.Type.SLICED;
//         o.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("q_ad/nativeEmbedBg", function (e, t) {
//             o.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             o.getComponent(cc.Sprite).spriteFrame.insetTop = 22;
//             o.getComponent(cc.Sprite).spriteFrame.insetBottom = 22;
//             o.getComponent(cc.Sprite).spriteFrame.insetLeft = 22;
//             o.getComponent(cc.Sprite).spriteFrame.insetRight = 22;
//         });
//         var i = new cc.Node();
//         i.addComponent(cc.Sprite);
//         o.addChild(i);
//         ailin_load("yinsixieyi/title", function (e, t) {
//             i.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//         });
//         var n = new cc.Node();
//         n.addComponent(cc.Sprite);
//         o.addChild(n);
//         n.getComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;
//         ailin_load("yinsixieyi/bg2", function (e, t) {
//             n.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             n.getComponent(cc.Sprite).spriteFrame.insetTop = 22;
//             n.getComponent(cc.Sprite).spriteFrame.insetBottom = 22;
//             n.getComponent(cc.Sprite).spriteFrame.insetLeft = 22;
//             n.getComponent(cc.Sprite).spriteFrame.insetRight = 22;
//         });
//         var a = new cc.Node();
//         a.name = "ScrollView";
//         var s = a.addComponent(cc.ScrollView);
//         s.horizontal = !1;
//         var r = new cc.Node();
//         r.addComponent(cc.Mask);
//         var c = new cc.Node();
//         c.addComponent(cc.Button);
//         c.addComponent(cc.Sprite);
//         ailin_load("yinsixieyi/btnOK", function (e, t) {
//             c.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(t);
//             ailin_sdk_manager.yincangBannerGuanggao();
//         });
//         var l = new cc.Node();
//         l.color = cc.Color.BLACK;
//         var d = l.addComponent(cc.Label);
//         d.fontSize = 20;
//         d.lineHeight = 24;
//         d.horizontal = cc.Label.HorizontalAlign.left;
//         d.overflow = cc.Label.Overflow.RESIZE_HEIGHT;
//         cc.winSize.width > cc.winSize.height
//             ? ((o.width = 800),
//               (o.height = 560),
//               (n.width = 700),
//               (n.height = 400),
//               (a.width = 700),
//               (a.height = 400),
//               (r.width = 700),
//               (r.height = 400),
//               (l.width = 685),
//               (i.y = 248),
//               (n.y = 18),
//               (a.y = 18),
//               (l.anchorY = 1),
//               (l.y = a.height / -2),
//               (c.y = -232))
//             : ((a.width = 469),
//               (a.height = 587),
//               (r.width = 469),
//               (r.height = 587),
//               (n.width = 469),
//               (n.height = 587),
//               (o.width = 527),
//               (o.height = 761),
//               (l.width = 451),
//               (i.y = 342),
//               (n.y = 18),
//               (a.y = 18),
//               (l.anchorY = 1),
//               (l.y = a.height / -2),
//               (c.y = -331));
//         a.addChild(r);
//         r.addChild(l);
//         s.content = l;
//         o.addChild(a);
//         o.addChild(c, 101);
//         c.on("click", function () {
//             t.destroy();
//         });
//         cc.winSize.width;
//         cc.winSize.height;
//         var u = "ailin";
//         "leYou" == window.ailin_huawei_team
//             ? (u = "leyouxi")
//             : "lieYou" == window.ailin_huawei_team
//             ? (u = "ailin")
//             : "dazheng" == window.ailin_huawei_team
//             ? (u = "dazheng")
//             : "jianyou" == window.ailin_huawei_team
//             ? (u = "jianyou")
//             : "huaxun" == window.ailin_huawei_team
//             ? (u = "huaxun")
//             : "zhangShangLeYuan" == window.ailin_huawei_team
//             ? (u = "zsleyuan")
//             : "duolewangguo" == window.ailin_huawei_team && (u = "duolewangguo");
//         var h = "https://idata.flowerme.com/comm/company/" + u + "/app/src/main/assets/privacypolicy.txt";
//         cc.loader.load(h, function (e, t) {
//             console.log("ailin----------------", t, "   err:", e);
//             d.string = t;
//         });
//     },
//     addImage: function (e, t, o) {
//         if (!(t > 12 || t < 1)) {
//             cc.loader.load(e + t + (14 == ailin_sdk_manager.huoqu_xitong_pingtai() ? ".png" : ".jpg"), function (i, n) {
//                 if (!i) {
//                     var a = new cc.SpriteFrame();
//                     a.setTexture(n);
//                     var s = new cc.Node();
//                     s.anchorY = 1;
//                     s.anchorX = 0.5;
//                     var r = s.addComponent(cc.Sprite);
//                     r.spriteFrame = a;
//                     r.sizeMode = cc.Sprite.SizeMode.CUSTOM;
//                     o.addChild(s);
//                     var c = cc.winSize.width / s.width;
//                     s.width = s.width * c;
//                     s.height = s.height * c;
//                     AL_Framework_al_interface.addImage(e, t + 1, o);
//                 }
//             });
//         }
//     }
// };


window.AL_Framework_al_interface = {
    /**
     * 显示吐司消息
     * @param {string} message - 要显示的消息
     */
    showToast: function (message) {
        const toastNode = new cc.Node();
        cc.director.getScene().addChild(toastNode, 99999);
        toastNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);

        toastNode.runAction(
            cc.sequence(
                cc.moveBy(0.7, 0, 200).easing(cc.easeBackOut(2)),
                cc.fadeOut(0.7),
                cc.removeSelf()
            )
        );

        const backgroundNode = new cc.Node();
        toastNode.addChild(backgroundNode);
        const spriteComponent = backgroundNode.addComponent(cc.Sprite);
        
        ailin_load("common/toastBg", (error, texture) => {
            if (!error) {
                const spriteFrame = new cc.SpriteFrame(texture);
                spriteFrame.insetTop = 13;
                spriteFrame.insetBottom = 13;
                spriteFrame.insetLeft = 13;
                spriteFrame.insetRight = 13;
                
                spriteComponent.spriteFrame = spriteFrame;
                spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;
                spriteComponent.type = cc.Sprite.Type.SLICED;
                
                backgroundNode.width = 40;
                backgroundNode.height = 93;
            }
        });

        const layoutComponent = backgroundNode.addComponent(cc.Layout);
        layoutComponent.resizeMode = cc.Layout.ResizeMode.CONTAINER;
        layoutComponent.paddingLeft = 20;
        layoutComponent.paddingRight = 20;
        layoutComponent.paddingTop = 15;
        layoutComponent.paddingBottom = 15;

        const textNode = new cc.Node();
        backgroundNode.addChild(textNode);

        const labelComponent = textNode.addComponent(cc.Label);
        labelComponent.fontSize = 35;
        labelComponent.string = message;
    },

    /**
     * 显示模态框
     * @param {object} data - 模态框数据
     */
    showModal: function (data) {
        cc.loader.loadRes("Flower/module/modal/modalNode", (error, prefab) => {
            if (!error) {
                const modalNode = cc.instantiate(prefab);
                modalNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
                modalNode.getComponent("AL_Framework_al_modal").shezhi_shuju_duixiang(data);
                cc.director.getScene().addChild(modalNode);
            }
        });
    },

    /**
     * 显示层
     * @param {string} message - 显示的消息
     */
    xianshi_layer_ceng: function (message) {
        const layerNode = new cc.Node();
        cc.director.getScene().addChild(layerNode);
        layerNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);

        const backgroundNode = new cc.Node();
        layerNode.addChild(backgroundNode);
        backgroundNode.addComponent(cc.Sprite);

        ailin_load("qgameMoreGame/oppo_native_insters_layerBg", (error, texture) => {
            if (!error) {
                const spriteComponent = backgroundNode.getComponent(cc.Sprite);
                spriteComponent.spriteFrame = new cc.SpriteFrame(texture);
                spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;
                backgroundNode.width = cc.winSize.width;
                backgroundNode.height = cc.winSize.height;
                backgroundNode.opacity = 200;
            }
        });

        const textNode = new cc.Node();
        layerNode.addChild(textNode);

        const labelComponent = textNode.addComponent(cc.Label);
        labelComponent.overflow = cc.Label.Overflow.RESIZE_HEIGHT;
        labelComponent.horizontalAlign = cc.Label.HorizontalAlign.CENTER;
        labelComponent.verticalAlign = cc.Label.VerticalAlign.CENTER;
        labelComponent.fontSize = 35;
        labelComponent.string = message;
        textNode.width = cc.winSize.width;

        backgroundNode.addComponent(cc.Button);
        backgroundNode.on("click", () => layerNode.destroy());
    },

    /**
     * 显示加载
     * @param {object} data - 加载数据
     * @returns {cc.Node}
     */
    showLoading: function (data) {
        const loadingNode = new cc.Node();
        cc.director.getScene().addChild(loadingNode);
        loadingNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);

        const bgNode = new cc.Node();
        loadingNode.addChild(bgNode);
        bgNode.addComponent(cc.Sprite);
        bgNode.addComponent(cc.BlockInputEvents);

        ailin_load("qgameMoreGame/oppo_native_insters_layerBg", (error, texture) => {
            if (!error) {
                const spriteComponent = bgNode.getComponent(cc.Sprite);
                spriteComponent.spriteFrame = new cc.SpriteFrame(texture);
                spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;
                bgNode.width = cc.winSize.width;
                bgNode.height = cc.winSize.height;
                bgNode.opacity = 200;
                bgNode.addComponent(require("./AL_Framework_al_loading")).chushihua_view(data);
            }
        });

        return loadingNode;
    },

    /**
     * 显示微信二维码
     */
    xianshi_weixin_erweima: function () {
        const codeNode = new cc.Node();
        codeNode.width = cc.winSize.width;
        codeNode.height = cc.winSize.height;
        codeNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
        codeNode.addComponent(cc.BlockInputEvents);
        codeNode.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;

        // ailin_load("qgameMoreGame/oppo_native_insters_layerBg.png", (error, texture) => {
        //     if (!error) {
        //         const spriteComponent = codeNode.getComponent(cc.Sprite);
        //         spriteComponent.spriteFrame = new cc.SpriteFrame(texture);
        //         codeNode.width = cc.winSize.width;
        //         codeNode.height = cc.winSize.height;
        //         ailin_sdk_manager.yincangBannerGuanggao();
        //     }
        // });

        cc.director.getScene().addChild(codeNode);
        cc.game.addPersistRootNode(codeNode);

        const qrNode = new cc.Node();
        codeNode.addChild(qrNode);
        qrNode.addComponent(cc.Sprite);

        // cc.loader.load("http://idata.flowerme.com/h5/commonResource/wechatCode.png", (error, texture) => {
        //     if (!error) {
        //         qrNode.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
        //     }
        // });

        const copyButton = new cc.Node();
        qrNode.addChild(copyButton, 999);
        copyButton.y = -225;
        copyButton.addComponent(cc.Sprite);

        // cc.loader.load("http://idata.flowerme.com/h5/commonResource/btnCopy.png", (error, texture) => {
        //     if (!error) {
        //         copyButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
        //     }
        // });

        // copyButton.on(cc.Node.EventType.TOUCH_END, () => {
        //     cc.loader.load("http://idata.flowerme.com/h5/commonResource/wxCopy.txt", (error, text) => {
        //         webCopyString(text);
        //     });
        // });

        const closeButton = new cc.Node();
        qrNode.addChild(closeButton);
        closeButton.setPosition(207, 274);
        closeButton.addComponent(cc.Sprite);

        // cc.loader.load("http://idata.flowerme.com/h5/commonResource/x.png", (error, texture) => {
        //     if (!error) {
        //         closeButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
        //         closeButton.on(cc.Node.EventType.TOUCH_END, () => codeNode.destroy());
        //     }
        // });
    },

    /**
     * 显示微信矩阵
     * @param {function} callback - 回调函数
     * @param {boolean} yincangBannerGuanggao - 是否隐藏横幅广告
     */
    xianshi_weixin_juzhen: function (callback = null, yincangBannerGuanggao = true) {
        const matrixNode = new cc.Node();
        matrixNode.width = cc.winSize.width;
        matrixNode.height = cc.winSize.height;
        matrixNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
        matrixNode.addComponent(cc.BlockInputEvents);
        matrixNode.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("common/bg2", (error, texture) => {
            if (!error) {
                matrixNode.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
                matrixNode.width = cc.winSize.width;
                matrixNode.height = cc.winSize.height;
                if (yincangBannerGuanggao) ailin_sdk_manager.yincangBannerGuanggao();
            }
        });

        cc.director.getScene().addChild(matrixNode);

        const titleNode = new cc.Node();
        titleNode.addComponent(cc.Sprite);
        titleNode.setPosition(0, cc.winSize.height / 2 - 100);
        matrixNode.addChild(titleNode, 2);

        ailin_load("common/sl", (error, texture) => {
            if (!error) {
                titleNode.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
                console.log("btn===========titleNode ", titleNode);
            }
        });

        const continueButton = new cc.Node();
        continueButton.addComponent(cc.Sprite);
        continueButton.setPosition(0, -cc.winSize.height / 2 + 150);
        matrixNode.addChild(continueButton, 2);

        ailin_load("common/jx", (error, texture) => {
            if (!error) {
                continueButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
                console.log("btn===========btnContinue ", continueButton);
            }
        });

        continueButton.on(cc.Node.EventType.TOUCH_END, () => {
            if (callback) callback();
            matrixNode.destroy();
        });

        ailin_sdk_manager.instance.show_Custom_Ad({ node: matrixNode });
        ailin_sdk_manager.yincangBannerGuanggao();
        ailin_sdk_manager.guanbiHeziBannerGuanggao();
    },

    /**
     * 显示隐私协议
     * @param {function} callback - 回调函数
     */
    xianshiYinsixieyi: function (callback = null) {
        const ysxyNode = new cc.Node();
        ysxyNode.width = cc.winSize.width;
        ysxyNode.height = cc.winSize.height;
        ysxyNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
        ysxyNode.addComponent(cc.BlockInputEvents);
        ysxyNode.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("qgameMoreGame/oppo_native_insters_layerBg", (error, texture) => {
            if (!error) {
                ysxyNode.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
                ysxyNode.width = cc.winSize.width;
                ysxyNode.height = cc.winSize.height;
                ailin_sdk_manager.yincangBannerGuanggao();
            }
        });

        cc.director.getScene().addChild(ysxyNode);
        cc.game.addPersistRootNode(ysxyNode);

        const containerNode = new cc.Node();
        containerNode.width = 624;
        containerNode.height = 710;
        containerNode.scale = Math.min(cc.winSize.width, cc.winSize.height) / 720;
        ysxyNode.addChild(containerNode);

        const spriteComponent = containerNode.addComponent(cc.Sprite);
        spriteComponent.type = cc.Sprite.Type.SIMPLE;
        spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;

        const isLandscape = cc.winSize.width > cc.winSize.height;
        ailin_load(isLandscape ? "yinsixieyi/hb/ys_bg" : "yinsixieyi/ys_bg", (error, texture) => {
            if (!error) {
                const spriteFrame = new cc.SpriteFrame(texture);
                containerNode.width = isLandscape ? 840 : 500;
                containerNode.height = isLandscape ? 580 : 710;
                spriteComponent.spriteFrame = spriteFrame;
            }
        });

        const ysxyButton = new cc.Node();
        ysxyButton.addComponent(cc.Sprite);
        ysxyButton.addComponent(cc.Button);
        ysxyButton.on("click", () => {
            console.log("ailin ----------------- btnYsxy");
            if (14 == ailin_sdk_manager.huoqu_xitong_pingtai()) {
                jsb.reflection.callStaticMethod(
                    "MyManager",
                    "OpenYinsiOrUser:type:",
                    "huaxun" == window.ailin_huawei_team ? 1 : 0,
                    0
                );
            } else {
                AL_Framework_al_interface.showBodyYS();
            }
        });

        const yhxyButton = new cc.Node();
        yhxyButton.addComponent(cc.Sprite);
        yhxyButton.addComponent(cc.Button);
        yhxyButton.on("click", () => {
            console.log("ailin ----------------- yhxy");
            if (14 == ailin_sdk_manager.huoqu_xitong_pingtai()) {
                jsb.reflection.callStaticMethod(
                    "MyManager",
                    "OpenYinsiOrUser:type:",
                    "huaxun" == window.ailin_huawei_team ? 1 : 0,
                    1
                );
            } else {
                AL_Framework_al_interface.showBodyYS("1");
            }
        });

        const rejectButton = new cc.Node();
        rejectButton.addComponent(cc.Sprite);
        rejectButton.addComponent(cc.Button);
        ailin_load("yinsixieyi/btnJJ", (error, texture) => {
            if (!error) {
                rejectButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });
        rejectButton.on("click", () => {
            if (0 == ailin_sdk_manager.instance.xieyi_shezhi) {
                AL_Framework_al_interface.xianshiYinsixieyiTishi(() => ysxyNode.destroy());
            } else {
                ysxyNode.destroy();
                if (callback) callback();
            }
        });

        const acceptButton = new cc.Node();
        acceptButton.addComponent(cc.Button);
        acceptButton.addComponent(cc.Sprite);
        ailin_load("yinsixieyi/btnTY", (error, texture) => {
            if (!error) {
                acceptButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });
        acceptButton.on("click", () => {
            ailin_sdk_manager.youxiTongyongShijianChuli("30001");
            ailin_user_default.set_bool_for_key("lieyou_huawei_needShowOk", false);
            cc.director.resume();
            if (callback) callback();
            ysxyNode.destroy();
        });

        if (isLandscape) {
            ysxyButton.setPosition(31, -32);
            ysxyButton.width = 99;
            ysxyButton.height = 19;

            yhxyButton.setPosition(-161, -32);
            yhxyButton.width = 99;
            yhxyButton.height = 19;

            rejectButton.setPosition(-150, -210);
            acceptButton.setPosition(150, -210);
        } else {
            ysxyButton.setPosition(165, -18);
            ysxyButton.width = 99;
            ysxyButton.height = 19;

            yhxyButton.setPosition(-150, -49);
            yhxyButton.width = 99;
            yhxyButton.height = 19;

            acceptButton.setPosition(120, -240);
            rejectButton.setPosition(-120, -240);
        }

        containerNode.addChild(ysxyButton);
        containerNode.addChild(yhxyButton);
        containerNode.addChild(acceptButton);
        containerNode.addChild(rejectButton);
    },

    /**
     * 显示隐私协议提示
     * @param {function} callback - 回调函数
     */
    xianshiYinsixieyiTishi: function (callback = null) {
        const node_tips = new cc.Node();
        node_tips.width = cc.winSize.width;
        node_tips.height = cc.winSize.height;
        node_tips.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
        node_tips.addComponent(cc.BlockInputEvents);
        node_tips.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("qgameMoreGame/oppo_native_insters_layerBg", (error, texture) => {
            if (!error) {
                node_tips.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
                node_tips.width = cc.winSize.width;
                node_tips.height = cc.winSize.height;
                ailin_sdk_manager.yincangBannerGuanggao();
            }
        });

        cc.director.getScene().addChild(node_tips);
        cc.game.addPersistRootNode(node_tips);

        const containerNode = new cc.Node();
        containerNode.width = 624;
        containerNode.height = 710;
        containerNode.scale = Math.min(cc.winSize.width, cc.winSize.height) / 720;
        node_tips.addChild(containerNode);

        const spriteComponent = containerNode.addComponent(cc.Sprite);
        spriteComponent.type = cc.Sprite.Type.SIMPLE;
        spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("tt/share_bg", (error, texture) => {
            if (!error) {
                const spriteFrame = new cc.SpriteFrame(texture);
                containerNode.width = 510;
                containerNode.height = 310;
                spriteComponent.spriteFrame = spriteFrame;
            }
        });

        const tipsImage = new cc.Node();
        tipsImage.addComponent(cc.Sprite);
        tipsImage.setPosition(0, 52);
        containerNode.addChild(tipsImage);

        ailin_load("yinsixieyi/tips", (error, texture) => {
            if (!error) {
                tipsImage.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        const rejectButton = new cc.Node();
        rejectButton.addComponent(cc.Sprite);
        rejectButton.setPosition(-110, -95);
        rejectButton.addComponent(cc.Button);
        containerNode.addChild(rejectButton);

        ailin_load("yinsixieyi/btnJJ", (error, texture) => {
            if (!error) {
                rejectButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        rejectButton.on("click", () => {
            if (0 == ailin_sdk_manager.instance.xieyi_shezhi) {
                const platform = ailin_sdk_manager.huoqu_xitong_pingtai();
                if ([3, 4].includes(platform)) {
                    qg.exitApplication({});
                } else if ([1].includes(platform)) {
                    wx.exitMiniProgram({});
                } else if ([11].includes(platform)) {
                    qq.exitMiniProgram({});
                } else if ([8].includes(platform)) {
                    tt.exitMiniProgram({});
                } else {
                    cc.game.end();
                }
            } else {
                node_tips.destroy();
                if (callback) callback();
            }
        });

        const acceptButton = new cc.Node();
        acceptButton.setPosition(110, -95);
        acceptButton.addComponent(cc.Button);
        acceptButton.addComponent(cc.Sprite);
        containerNode.addChild(acceptButton);

        ailin_load("yinsixieyi/btnTY", (error, texture) => {
            if (!error) {
                acceptButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        acceptButton.on("click", () => {
            ailin_sdk_manager.youxiTongyongShijianChuli("30001");
            ailin_user_default.set_bool_for_key("lieyou_huawei_needShowOk", false);
            cc.director.resume();
            if (callback) callback();
            node_tips.destroy();
        });
    },

    /**
     * 显示订单提示
     * @param {string} message - 提示消息
     * @param {function} callback - 回调函数
     */
    xianshiDingdanTishi: function (message = "", callback = null) {
        const orderTipsNode = new cc.Node();
        orderTipsNode.width = cc.winSize.width;
        orderTipsNode.height = cc.winSize.height;
        orderTipsNode.setPosition(cc.winSize.width / 2, cc.winSize.height / 2);
        
        const bgNode = new cc.Node();
        bgNode.width = cc.winSize.width;
        bgNode.height = cc.winSize.height;
        bgNode.opacity = 150;
        bgNode.addComponent(cc.BlockInputEvents);
        bgNode.addComponent(cc.Sprite).sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("qgameMoreGame/oppo_native_insters_layerBg", (error, texture) => {
            if (!error) {
                const spriteComponent = bgNode.getComponent(cc.Sprite);
                spriteComponent.spriteFrame = new cc.SpriteFrame(texture);
                bgNode.width = cc.winSize.width;
                bgNode.height = cc.winSize.height;
                ailin_sdk_manager.yincangBannerGuanggao();
            }
        });

        orderTipsNode.addChild(bgNode);
        cc.director.getScene().addChild(orderTipsNode);
        cc.game.addPersistRootNode(orderTipsNode);

        const contentNode = new cc.Node();
        contentNode.width = 624;
        contentNode.height = 710;
        contentNode.scale = Math.min(cc.winSize.width, cc.winSize.height) / 720;
        orderTipsNode.addChild(contentNode);

        const spriteComponent = contentNode.addComponent(cc.Sprite);
        spriteComponent.type = cc.Sprite.Type.SIMPLE;
        spriteComponent.sizeMode = cc.Sprite.SizeMode.CUSTOM;

        ailin_load("q_ad/nativeEmbedBg", (error, texture) => {
            if (!error) {
                const spriteFrame = new cc.SpriteFrame(texture);
                contentNode.width = 510;
                contentNode.height = 310;
                spriteComponent.spriteFrame = spriteFrame;
            }
        });

        const tipsImage = new cc.Node();
        tipsImage.addComponent(cc.Sprite);
        tipsImage.setPosition(0, 105);
        contentNode.addChild(tipsImage);

        ailin_load("yinsixieyi/wxtips", (error, texture) => {
            if (!error) {
                tipsImage.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        const messageNode = new cc.Node();
        const labelComponent = messageNode.addComponent(cc.Label);
        labelComponent.string = message;
        labelComponent.fontSize = 26;
        labelComponent.lineHeight = 32;
        labelComponent.overflow = cc.Label.Overflow.RESIZE_HEIGHT;
        labelComponent.horizontalAlign = cc.Label.HorizontalAlign.CENTER;
        labelComponent.verticalAlign = cc.Label.VerticalAlign.CENTER;
        messageNode.color = cc.Color.BLACK;
        messageNode.width = 480;
        messageNode.height = 160;
        messageNode.setPosition(0, 10);
        contentNode.addChild(messageNode);

        const rejectButton = new cc.Node();
        rejectButton.addComponent(cc.Sprite);
        rejectButton.setPosition(-110, -95);
        rejectButton.addComponent(cc.Button);
        contentNode.addChild(rejectButton);

        ailin_load("yinsixieyi/btnJJ", (error, texture) => {
            if (!error) {
                rejectButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        rejectButton.on("click", () => {
            console.log("User clicked reject button.");
            if (callback) callback(false);
            orderTipsNode.destroy();
        });

        const acceptButton = new cc.Node();
        acceptButton.setPosition(110, -95);
        acceptButton.addComponent(cc.Button);
        acceptButton.addComponent(cc.Sprite);
        contentNode.addChild(acceptButton);

        ailin_load("yinsixieyi/btnTY", (error, texture) => {
            if (!error) {
                acceptButton.getComponent(cc.Sprite).spriteFrame = new cc.SpriteFrame(texture);
            }
        });

        acceptButton.on("click", () => {
            console.log("User clicked accept button.");
            if (callback) callback(true);
            orderTipsNode.destroy();
        });
    },
};
